package com.atguigu.yygh.orders.utils;

import com.atguigu.yygh.common.utils.JwtHelper;

import javax.servlet.http.HttpServletRequest;

public class AuthContextHolder {

    public static Long getUserId(HttpServletRequest request){
        String token = request.getHeader("token");
        Long userId = JwtHelper.getUserId(token);
        return userId;
    }
}